package com.mz.mattress.client.api.biz;

import com.mz.mattress.api.common.Result;
import com.mz.mattress.api.entity.Device;
import com.mz.mattress.client.service.DeviceService;
import lombok.extern.slf4j.Slf4j;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.*;

@RestController
@RequestMapping("/device")
@Slf4j
public class DeviceController {

    @Autowired
    private DeviceService deviceService;

    @GetMapping("/info")
    public Result<Device> info(@RequestParam String deviceCode) {
        return deviceService.info(deviceCode);
    }

//    @GetMapping("/queryStatus")
//    public Result queryStatus(@RequestParam String deviceCode) {
//        return deviceService.queryStatus(deviceCode);
//    }

}
